package com.tuling.demo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;


/**
 * @author : fjc.dane@gmail.com
 * @createtime : 2021/12/16
 */

//@RestController = @Controller +  @ResponseBody
@Controller
@ResponseBody
@RequestMapping("/home")
public class HomeController {


    @RequestMapping("/login")
    public Map<String, Object> login() {
        Map<String, Object> map = new HashMap<>();
        map.put("code", "1");
        return map;
    }

}
